//
//  KLGoodsCell.m
//  used
//
//  Created by xalo on 16/7/17.
//  Copyright © 2016年 王凯. All rights reserved.
//

#import "KLGoodsCell.h"

@interface KLGoodsCell ()
@property (weak, nonatomic) IBOutlet UIImageView *imageV;
@property (weak, nonatomic) IBOutlet UILabel *titleLabel;
@property (weak, nonatomic) IBOutlet UILabel *priceLabel;
@property (weak, nonatomic) IBOutlet UILabel *orginalPrice;
@property (weak, nonatomic) IBOutlet UILabel *cityLabel;

@end


@implementation KLGoodsCell

- (void)setGoodModel:(KLGood *)goodModel {
    _goodModel = goodModel;

    if (goodModel.imageurls.count) {
        
        [self.imageV sd_setImageWithURL:[NSURL URLWithString:goodModel.imageurls[0]]];
    }else {
        self.imageV.image = [UIImage imageNamed:@"top"];
    }
    self.titleLabel.text = goodModel.goodsname;
    self.priceLabel.text = goodModel.saleprice.description;
    self.orginalPrice.text = goodModel.originprice.description;
    self.cityLabel.text = goodModel.city;
}



@end
